import request from "@/utils/request";

// 查询商品交易记录列表
export function listRecord(query) {
  return request({
    url: "/library/mbTradingRecord/list",
    method: "get",
    params: query,
  });
}

// 查询商品交易记录详细
export function getRecord(id) {
  return request({
    url: "/library/mbTradingRecord/" + id,
    method: "get",
  });
}

// 新增商品交易记录
export function addRecord(data) {
  return request({
    url: "/library/mbTradingRecord",
    method: "post",
    data: data,
  });
}

// 修改商品交易记录
export function updateRecord(data) {
  return request({
    url: "/library/mbTradingRecord",
    method: "put",
    data: data,
  });
}

// 删除商品交易记录
export function delRecord(id) {
  return request({
    url: "/library/mbTradingRecord/" + id,
    method: "delete",
  });
}
